package com.dt.dubai.mber.entity;

import com.dt.dubai.core.comm.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.*;

import javax.persistence.Table;
import javax.validation.constraints.*;


/*
 * 顾客地址表
 */

@Data
@Table(name = "dt_mber_customer_addr")
@EqualsAndHashCode(callSuper = false)
public class MberCustomerAddrEntity extends BaseEntity {

    //顾客登录记录ID
    @NotNull(message = "customerRecordId参数不能为空")
    Long customerRecordId;

    //邮编
    @NotNull(message = "zipCode参数不能为空")
    @Length(min = 0, max = 6, message = "zipCode参数最大长度不6")
    String zipCode;

    //省份城市区
    @NotNull(message = "cityProvinceArea参数不能为空")
    @Length(min = 0, max = 12, message = "cityProvinceArea参数最大长度不12")
    String cityProvinceArea;

    //快递地址
    @NotNull(message = "expressAddress参数不能为空")
    @Length(min = 0, max = 120, message = "expressAddress参数最大长度不120")
    String expressAddress;

    //默认地址标识 0-否,1-是
    Boolean defaultAddress;


}
